import request from '@/utils/request'

export function getUser(data) {
  return request({
    url: 'clinic/user/list',
    method: 'post',
    data
  })
}

export function addUser(data) {
  return request({
    url: '/clinic/user/add',
    method: 'POST',
    data
  })
}

export function editUser(data) {
  return request({
    url: '/clinic/user/edit',
    method: 'POST',
    data
  })
}

export function resetPwd(data) {
  return request({
    url: '/clinic/user/change',
    method: 'POST',
    data
  })
}

export function grantRole(data) {
  return request({
    url: '/clinic/role/grant',
    method: 'POST',
    data
  })
}

export function grantDept(data) {
  return request({
    url: '/clinic/dept/grant',
    method: 'POST',
    data
  })
}
